<?php use_stylesheets_for_form($form) ?>
<?php use_javascripts_for_form($form) ?>

<form action="<?php echo url_for('note/'.($form->getObject()->isNew() ? 'create' : 'update?nte_id='.$form->getObject()->getNteId())) ?>" method="post">

<?php if (!$form->getObject()->isNew()): ?>
<input type="hidden" name="sf_method" value="put" />
<?php endif; ?>

<?php echo $form->renderHiddenFields(false) ?>
<?php echo $form->renderGlobalErrors() ?>

<div>
Note : <br>
<?php echo $form['nte_note']->renderError() ?>
<?php echo $form['nte_note']->render(array('cols' => 50)) ?>
</div>

<input type="submit" value="Enregistrer" />
</form>


<div class="action">
<?php 
	echo link_to('Retour liste', 'note/index', array('class' => 'action'));
		// echo link_to('Retour tâche', 'tache/show?tac_id='.$form->getObject()->getNteRefId());
?>

<?php 
	if (!$form->getObject()->isNew()) {
		echo '&nbsp';
		echo link_to('Supprimer', 'note/delete?nte_id='.$form->getObject()->getNteId(), array('class' => 'action', 'method' => 'delete', 'confirm' => 'Etes-vous sûr ?'));
	}
?>
</div>
